var root = ui("$");
var nf = sm("do_Notification");
var do_GridView_1 = ui("do_GridView_1");
var deviceone = require("deviceone");
var communityUtil = require("helper/community");
var helperOpen = require("helper/open");
var qqHttp = require("helper/http");
var bizzType = require("helper/bizzType");
var pubUrl = require("url/pub");
// UI
var aLayoutType = ui("aLayoutType");
var linearLayoutRow = ui("linearLayoutRow");
var labelContent = ui("labelContent");
var labelTypeName=ui("labelTypeName");
var fontColorItem=['F953F4FF','EC8873FF','6695DBFF'];
// 设置数据绑定的映射关系
root.setMapping({ // 此处的Mapping只能设置在 RootView 上 ;
	"aLayoutType.tag" : "type",
	"linearLayoutRow.tag" : "creatorId",
	"labelTypeName.text" : "typeName",
	"labelContent.text" : "content",
	"labelTime.text" : "dayMinutesNewAt",
	"labelReplayCount.text" : "replyCount",
	"do_GridView_1.items" : "imgItems",
	"do_GridView_1.visible" : "hasImg"
});
root.on("dataRefreshed", function() {
	labelTypeName.fontColor=fontColorItem[aLayoutType.tag-1];
})

/*aLayoutType.on("touch", function() {
	helperOpen.open("source://view/search/community/message/communityMessageSearchList.ui",{
		type : this.tag,
		typeName:ui("labelTypeName").text
	});
})*/